package com.ww.learn.oop.property

import com.ww.learn.oop.Car
import java.lang.Exception

fun main() {
    val car = Car(2019, "Red")
    car.color = "Green"
    car.fueLevel--
    println(car.fueLevel)

    try {
        car.color = ""
    } catch (ex: Exception) {
        println(ex.message)
    }
    println(car.color)
}